﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace BDSim
{
    public enum EStationType
    {
        /// <summary>
        /// 主控站
        /// </summary>
        MasterStation,
        
        /// <summary>
        /// 注入站
        /// </summary>
        InjectionStation,
        
        /// <summary>
        /// 监测站
        /// </summary>
        MonitorStation,

    }

    /// <summary>
    /// 定轨误差类型
    /// </summary>
    public enum EOrbitDetermineErrCoordinateType
    {
        /// <summary>
        /// 输出为RTN坐标系误差
        /// </summary>
        RTN,

        /// <summary>
        /// 输出为ECI直角坐标系误差
        /// </summary>
        ECI,
    }

    #region 电离层拟合参数
    /// <summary>
    /// 电离层八参数
    /// </summary>
    public struct IonoSphere_8
    {
        public double Alpha0;
        public double Alpha1;
        public double Alpha2;
        public double Alpha3;
        public double Beta0;
        public double Beta1;
        public double Beta2;
        public double Beta3;
    }

    /// <summary>
    /// 电离层九参数
    /// </summary>
    public struct IonoSphere_9
    {
        public double A00;
        public double A10;
        public double A11;
        public double B11;
        public double A20;
        public double A21;
        public double B21;
        public double A22;
        public double B22;
    }

    /// <summary>
    /// 电离层 14参数
    /// </summary>
    public struct IonoSphere_14
    {
        /// <summary>
        /// 0-63，纳秒（以下为电离层14参）
        /// </summary>
        public double A1;

        /// <summary>
        /// -224-217，纳秒/π
        /// </summary>
        public double B;

        /// <summary>
        /// (Alpha0) 
        /// </summary>
        public double Alpha0;

        /// <summary>
        /// α1
        /// </summary>
        public double Alpha1;

        /// <summary>
        /// α2
        /// </summary>
        public double Alpha2;

        /// <summary>
        /// α3
        /// </summary>
        public double Alpha3;

        /// <summary>
        /// (Beta0)
        /// </summary>
        public double Beta0;

        /// <summary>
        /// β1
        /// </summary>
        public double Beta1;


        /// <summary>
        /// β2
        /// </summary>
        public double Beta2;


        /// <summary>
        /// β3
        /// </summary>
        public double Beta3;

        /// <summary>
        /// 0(Gamma0)
        /// </summary>
        public double Gamma0;

        /// <summary>
        /// Gamma01
        /// </summary>
        public double Gamma1;

        /// <summary>
        /// Gamma02
        /// </summary>
        public double Gamma2;

        /// <summary>
        /// Gamma03
        /// </summary>
        public double Gamma3;
    };


    /// <summary>
    /// 电离层参数拟合的输入结构体
    /// </summary>
    public struct IonoFit_Input
    {
        /// <summary>
        /// 拟合的UTC时间
        /// </summary>
        public UTCTime FitTime;

        /// <summary>
        /// 拟合模型标识，1是8参数Klobuchar模型， 2是14参数Klobuchar模型， 3是9参数低阶球谐模型
        /// </summary>
        public int Select;
    }

    /// <summary>
    /// 电离层拟合输出结构体
    /// </summary>
    public struct IonoFit_Output
    {
        /// <summary>
        /// Klobuchar 8 参数
        /// </summary>
        public IonoSphere_8 EightIonoData;

        /// <summary>
        /// Klobuchar 14 参数
        /// </summary>
        public IonoSphere_14 ForteenIonoData;

        /// <summary>
        /// 低阶球谐模型 9 参数
        /// </summary>
        public IonoSphere_9 NineIonoData;
    }

    /// <summary>
    /// 主控站电离层拟合输出信息
    /// </summary>
    public struct IonoFit_OutputMsg
    {
        /// <summary>
        /// 拟合时间（只需到天即可）
        /// </summary>
        public UTCTime FitDay;
       
        /// <summary>
        /// 拟合系数
        /// </summary>
        public IonoFit_Output IonoFitOutput; 
 
    }

    #endregion

}
